home *** CD-ROM | disk | FTP | other *** search
- property posH, posV, sp, cstNum, cstNam, speedH, speedV, orbitH, orbitV, orbSpeed, whchDir
- global flyList, spFlyList, spBox, offset, spCow, orbFlag, flyMidPos, spRing
-
- on new me, asp, aPosH, aPosV, aCstNam, aSpdH, aSpdV, aOrbH, aOrbV, aOrbSpd, aDir
- sp = asp
- posH = aPosH
- posV = aPosV
- cstNam = aCstNam
- cstNum = the number of member cstNam
- speedH = aSpdH
- speedV = aSpdV
- orbitH = aOrbH
- orbitV = aOrbV
- orbSpeed = aOrbSpd
- whchDir = aDir
- SwapPic(me)
- FlyPos(me)
- puppetSprite(sp, 1)
- set the backColor of sprite sp to 0
- set the foreColor of sprite sp to 255
- set the ink of sprite sp to 36
- set the blend of sprite sp to 100
- return me
- end
-
- on SwapPic me
- cstNum = the number of member cstNam
- set the memberNum of sprite sp to cstNum
- updateStage()
- end
-
- on FlyPos me
- set the locH of sprite sp to posH
- set the locV of sprite sp to posV
- end
-
- on kill me
- if not soundBusy(2) then
- puppetSound(2, member("Zap"))
- end if
- cstNam = "Fly2"
- SwapPic(me)
- Wait(1)
- posH = -1000
- FlyPos(me)
- add(spFlyList, sp)
- temp = getPos(flyList, me)
- deleteAt(flyList, temp)
- end
-
- on orbit me
- global orbCounter
- if orbFlag = 1 then
- orbCounter = orbCounter + 1
- if orbCounter > 30 then
- orbitV = orbitV + 2
- orbCounter = 0
- end if
- end if
- temp1 = flyMidPos
- temp2 = the locV of sprite spCow
- posH = temp1 + (orbitH * sin(the ticks / orbSpeed))
- posV = temp2 + (orbitV * cos(the ticks / orbSpeed))
- FlyPos(me)
- end
-